using System;

namespace UserManagementService.Exceptions;

/// <summary>
/// 用户已停用异常
/// </summary>
public class UserAlreadyInactiveException : UserManagementException
{
    public Guid UserId { get; }
    public string UserName { get; }

    public UserAlreadyInactiveException(Guid userId, string userName)
        : base($"用户 '{userName}' 已经处于停用状态")
    {
        UserId = userId;
        UserName = userName;
    }

    public UserAlreadyInactiveException(Guid userId, string userName, Exception innerException)
        : base($"用户 '{userName}' 已经处于停用状态", innerException)
    {
        UserId = userId;
        UserName = userName;
    }
}